package 集合框架.HashMap源码解析;

import java.util.HashMap;
import java.util.Map;

/**
 * @program: algorithm
 * @description:
 * @author: 陈恩涛
 * @create: 2022-01-06 11:13
 **/
public class TestHashMap {
    public static void main(String[] args) {
        Map<String, Object> map = new HashMap<>(7);
        map.put("a", 1);
        map.put("b", 3);
        map.put("c", 6);
        map.put("s", 6);
        map.put("z", 6);
        map.put("w", 6);
        map.put("q", 6);
        map.put("j", 6);
        map.put("k",7);
        map.put(null, null);
        map.get("w");
        for (Map.Entry<String, Object> entry : map.entrySet()) {
            System.out.println(entry.getKey()+":"+entry.getValue());
        }
    }
}
